package org.novelhibernate.support.logging.annotation;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * This class identify the extra action when exception occurs, 
 * 
 * Note that the sequence of exception within the throws statement, the most
 * bottom level exception should come first, those common super exception e.g
 * Exception, Error, Throwable should come last, otherwise the handler would be
 * executed correctly 
 * @author Tao Chen
 *
 */
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface ExceptionRegistry {

	// must be as the same sequence as throw exception
	int[] handlerMehotdID();
	
	Class<?>[] handleException();

}
